package com.beeantec.jnrerc.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author anthony
 * @since 2022-01-19
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("mission")
public class Mission extends Model<Mission> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 任务类型(0悬赏任务1竞标任务)
     */
    private Integer type;

    /**
     * 创建时间
     */
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    /**
     * 开始时间
     */
    private Date startTime;

    /**
     * 结束时间
     */
    private Date endTime;

    /**
     * 任务状态(0发布1参与2选中3提交4分配奖励5完成)
     */
    private Integer status;

    /**
     * 任务内容
     */
    private String content;

    /**
     * 任务标题
     */
    private String title;

    /**
     * 任务发起人id
     */
    private Long creatorId;

    /**
     * 奖励值
     */
    private Integer award;

    /**
     * 奖励类型(0积分1魅力值)
     */
    private Integer awardType;


    public static final String ID = "id";

    public static final String TYPE = "type";

    public static final String CREATE_TIME = "create_time";

    public static final String START_TIME = "start_time";

    public static final String END_TIME = "end_time";

    public static final String STATUS = "status";

    public static final String CONTENT = "content";

    public static final String TITLE = "title";

    public static final String CREATOR_ID = "creator_id";

    public static final String AWARD = "award";

    public static final String AWARD_TYPE = "award_type";

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
